Production plans are usually made at production sites to achieve efficient production. The production plan is based on production capacity of a facility and personnel, delivery time, and inventory. When making a production plan for machining, a planner of the production plan expresses the production capacity of a facility in terms of machining time for each workpiece. Thus, when making the production plan, the planner of the production plan needs to know in advance the machining time of each workpiece. Knowing the machining time accurately is also important for the planner of the production plan to make an accurate production plan.
Patent Literature 1 discloses an invention for calculating the machining time of a numerically controlled machine tool on the basis of an NC program. The invention disclosed in Patent Literature 1 grasps the machining time for each line (hereinafter referred to as a block) of a machining program. The invention disclosed in Patent Literature 1 calculates execution time of a block from the amount and speed of movement when the block specifies axis move command. The invention disclosed in Patent Literature 1 sets preset operating time as the execution time of a block when the block specifies an auxiliary function command. After calculating the execution time of each block, the invention disclosed in Patent Literature 1 calculates the machining time by adding the execution times of the blocks in the order of execution of the blocks.
A numerically controlled machine tool including a plurality of systems that can be controlled independently can perform program search and cycle start independently for each system. The numerically controlled machine tool is also controlled using a wait command to simultaneously execute a plurality of blocks in different systems. When the wait command is set for a plurality of blocks to be started simultaneously, the numerically controlled machine tool is controlled such that a system first completing execution of a block preceding the block to which the wait command is set waits for a system completing execution of the block later to match the timing for starting the execution of the blocks. The system waiting for another system by the wait command has a wait time. The numerically controlled machine tool needs to calculate the wait time in order to calculate machining time of each system. Patent Literature 2 discloses a method of calculating the machining time including the wait time. When a system has a waiting block, the method disclosed in Patent Literature 2 finds the elapsed times to the corresponding waiting block in other systems and, by using the longest elapsed time as the start time for the next waiting block, calculates the elapsed time to the next block.